package aos.system.modules.message;

import aos.framework.core.dao.SqlDao;
import aos.framework.web.router.HttpModel;
import aos.system.common.id.IdService;
import aos.system.common.utils.SystemCons;
import aos.system.dao.AosGroupDao;
import aos.system.dao.AosOrgDao;
import aos.system.dao.AosUserGroupDao;
import aos.system.dao.po.AosOrgPO;
import aos.system.modules.cache.CacheUserDataService;
import org.springframework.beans.factory.annotation.Autowired;

public class NoticeDraftService {

    @Autowired
    private AosGroupDao aosGroupDao;
    @Autowired
    private AosOrgDao aosOrgDao;
    @Autowired
    private SqlDao sqlDao;
    @Autowired
    private IdService idService;
    @Autowired
    private CacheUserDataService cacheUserDataService;
    @Autowired
    private AosUserGroupDao aosUserGroupDao;
    /**
     * 群组管理页面初始化
     *
     * @param httpModel
     * @return
     */
    public void init(HttpModel httpModel) {
        AosOrgPO aosOrgPO = aosOrgDao.selectByKey(httpModel.getUserModel().getAosOrgPO().getId());
        httpModel.setAttribute("rootPO", aosOrgPO);
        httpModel.setAttribute("super_user_id", SystemCons.SUPER_USER_ID);
        httpModel.setViewPath("system/noticeDraft.jsp");
    }
}
